package com.atguigu.ssyx.product.mapper;


import com.atguigu.ssyx.model.product.Category;
import com.atguigu.ssyx.model.sys.Ware;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import org.springframework.stereotype.Repository;

/**
 * <p>
 * 商品三级分类 Mapper 接口
 * </p>
 *
 * @author atguigu
 * @since 2025-09-13
 */
@Repository
public interface CategoryMapper extends BaseMapper<Category> {
    @Select("select * from `shequ-product`.category where name = #{name}")
    Ware selectCategoryByName(String name);
    @Update("update `shequ-product`.category set is_deleted = 0,update_time = now() where id = #{id}")
    void updateIsdeleteById(Long id);
}
